<link type="text/css" href="/public/library/jquery/calendar/excite-bike/ui.all.css" rel="stylesheet" media="screen" />
<link rel="stylesheet" href="/public/library/jquery/calendar/excite-bike/jquery-ui-1.7.1.custom.css" type="text/css" media="screen" />
<link rel="stylesheet" href="/public/themes/second/css/navigationTab.css" type="text/css">
<!--<script type="text/javascript" src="/public/library/jquery/jquery.js"></script>-->
<script type="text/javascript" src="/public/library/jquery/calendar/ui.core.js"></script>
<script type="text/javascript" src="/public/library/jquery/calendar/ui.datepicker.js"></script>
<script type="text/javascript" src="/public/library/jquery/calendar/ui.datepicker-lang.js"></script>
<script type="text/javascript" src="/public/library/jquery/calendar/amlich.js"></script>
<script type="text/javascript" src="/public/library/hvn/captcha.redraw.js"></script>
<script src="/public/library/hvn/tour.js" type="text/javascript"></script>

<script language="Javascript">
	$(function() {  
		getType();
	});
	
	function populate_category_checkboxes()
	{
		<?if(!empty($this->type)):?>
		<?foreach ($this->type as $t) :?>
			$("input:checkbox[name=type[]]").filter("[value=<?=$t?>]").trigger("click");
		<?endforeach?>
		<?endif?>
	}
</script>
<div class="successMessage"><?=$this->successMessage ?></div>
<div class="errorMessage"><?=$this->errorMessage ?></div>
<form id="newEvent" accept-charset="UTF-8" action="<?= $this->escape($this->form->getAction()) ?>"
      method="<?= $this->escape($this->form->getMethod()) ?>">
<?if($this->mode == 'edit') :?>
<ul  class="navigationTab">
<li class="selected"> <a href="<?=$this->hvnUrl(array('module' => 'tour', 'action' => 'edit'))?>?id=<?=$this->id?>"> <?=t(802)?> </a> </li>
<li> <a href="<?=$this->hvnUrl(array('module' => 'tour', 'action' => 'new-tleg'))?>?tid=<?=$this->id?>&leg_number=<?=$this->leg_number?>"> New Tleg </a> </li>
<li> <a href="<?=$this->hvnUrl(array('module' => 'tour', 'action' => 'gallery'))?>?id=<?=$this->id?>"> <?=t(6)?> </a> </li>
<li> <a href="<?=$this->hvnUrl(array('module' => 'tour', 'action' => 'list-tleg'))?>?id=<?=$this->id?>">Tleg </a> </li>
<li> <a target="_blank" href="<?=$this->hvnUrl(array('module' => 'tour', 'action' => 'view'))?>?id=<?=$this->id?>"> <?=t(134)?> </a> </li>
</ul>
<?endif?>

<h1 style="padding-left:15px"><?=t(841) ?></h1>
<br/>
<fieldset class="expansible"><legend><span><?=t(821) ?></span></legend>
<table> 
	<tr>
		<td width="100px"> <?=t(810) ?></td>
		<td width="220px"> <?=$this->form->name ?></td>
		
<?if(isset($this->form->tour_lang)) :?>
		<td width="100px"><?=t(81)?></td>
		<td width="220px"><?=$this->form->tour_lang ?></td>
<?else:?>
		<td></td>
		<td></td>
<?endif ?>
	</tr>
	<tr>
		<td width="100px"><?=t(822) ?></td>
		<td width="220px"><?=$this->form->itinery ?></td>
	</tr>
	<tr>
		<td width="100px"><?=t(816) ?></td>
		<td width="220px"><?=$this->form->category_tour ?></td>
	</tr>
	<tr >
		<td></td>
		<td id="sub-type">
	 	</td>
	 </tr>
	<tr>
		<td width="100px"><?=t(814) ?></td>
		<td width="220px"><?=$this->form->departure_date?></td>
		<td width="100px"><?=t(815) ?></td>
		<td width="220px"><?=$this->form->return_date?></td>
	</tr>
	<tr>
		<td width="100px"><?=t(813) ?> <?=t(826) ?></td>
		<td  width="220px"><?=$this->form->total_duration ?></td>
		<td></td>
		<td></td>
	</tr>
	<tr>
		<td width="100px"><?=t(811) ?></td>
		<td  width="220px"><?=$this->form->price?></td>
		<td width="100px"><?=t(827) ?><?=$this->form->price_currency ?></td>
		<td  width="220px"></td>
	</tr>
	
</table>
</fieldset>


<fieldset class="expansible"><legend><span><?=t(823) ?></span></legend>
<table>
	<tr>
		<td width="100px"><?=t(810) ?></td>
		<td  width="220px"><?=$this->form->organizer_name?></td>
		<td></td>
		<td></td>
	</tr>
	<tr>
		<td width="100px"><?=t(824) ?></td>
		<td  width="220px"><?=$this->form->organizer_website?></td>
		<td></td>
		<td></td>
	</tr>
</table>

<?=t(825) ?>:<br/><br/>
<div style="padding-left:10px"> <?=$this->form->organizer_contact ?>
</div>
<br/>
</fieldset>

<fieldset class="expansible"><legend><span><?=t(21) ?></span></legend>
<div>
<b><?=t(21) ?></b>:<br/><?=$this->form->description?>
</div>
</fieldset>
<? if(!empty($this->form->captcha_newtour)) :?>
<div>
<?=$this->form->captcha_newtour ?>
<a href="javascript:void()" class="redraw"> <?=t(22) ?></a>
</div>
<?endif ?>

<? if(isset($this->form->status)) :?>
<br/>
<?=t(2) ?>: <?=$this->form->status ?>
<br/>
<?endif ?>

<?=$this->form->submit ?>
<input type ="hidden" name = "id" value = "<?=$this->id; ?>" />
<input type ="hidden" name = "article_id" value = "<?=$this->article_id; ?>" />
</form>

<script>
$(function(){
	$("#category_tour").trigger("change");
	$("#sub-type").trigger("click");
});
</script>